<!--{include(pe_tpl('header_dialog.html'));}-->
<div class="now">
	<!--{foreach($ini['prokey_state'] as $k=>$v):}-->
	<a href="admin.php?mod=prokey&act=list&state={$k}&id={$product_id}" <!--{if($k==$_g_state):}-->class="sel"<!--{endif;}-->>{$v}（{$tongji[$k]}）<i></i></a>
	<!--{endforeach;}-->
	<a href="admin.php?mod=prokey&act=add&id={$product_id}" id="fabu" onclick="return parent.pe_dialog(this, '手动录入卡密', 900, 650)">手动录入</a>
	<a href="admin.php?mod=prokey&act=import&id={$product_id}" id="fabu" onclick="return pe_dialog(this, '批量导入卡密', 600, 300)">批量导入</a>
	<div class="clear"></div>
</div>
<div class="right_main">
	<form method="post" id="form">
	<table border="0" cellspacing="0" cellpadding="0" class="list" id="product_list">
	<tr>
		<th class="bgtt" width="20"><input type="checkbox" name="checkall" onclick="pe_checkall(this, 'prokey_id')" /></th>
		<th class="bgtt" width="50">ID号</th>
		<th class="bgtt" width="">卡密信息</th>
		<th class="bgtt" width="150">有效期至</th>
		<th class="bgtt" width="150">订单ID</th>
		<th class="bgtt" width="100">状态</th>
		<th class="bgtt" width="110">操作</th>
	</tr>
	<!--{foreach($info_list as $v):}-->
	<tr>
		<td><input type="checkbox" name="prokey_id[]" value="{$v['prokey_id']}" /></td>
		<td>{$v['prokey_id']}</td>
		<td>{$v['prokey_value']}</td>
		<td>{$v['prokey_edate']}</td>
		<td>{$v['order_id']?$v['order_id']:'-'}</td>
		<td>
			<!--{if($v['prokey_state'] == 'new'):}-->
			<span class="">{$ini['prokey_state'][$v['prokey_state']]}</span>
			<!--{elseif($v['prokey_state'] == 'success'):}-->
			<span class="cgreen">{$ini['prokey_state'][$v['prokey_state']]}</span>			
			<!--{elseif($v['prokey_state'] == 'expire'):}-->
			<s class="cbbb">{$ini['prokey_state'][$v['prokey_state']]}</s>
			<!--{endif;}-->			
		</td>
		<td>
			<a href="admin.php?mod=prokey&act=edit&id={$v['prokey_id']}" class="admin_edit mar3" onclick="return pe_dialog(this, '修改卡密', 700, 300)">修改</a>
			<a href="javascript:pe_confirm('删除', 'admin.php?mod=prokey&act=del&id={$v['prokey_id']}&token={$pe_token}')" class="admin_del">删除</a>
		</td>
	</tr>
	<!--{endforeach;}-->
	</table>
	</form>
</div>
<div class="right_bottom">
	<span class="fl">
		<input type="checkbox" name="checkall" onclick="pe_checkall(this, 'prokey_id')" />
		<input type="button" onclick="pe_checksel('prokey_id') && pe_confirm('批量删除', 'admin.php?mod=prokey&act=del&token={$pe_token}', true)" value="批量删除" />
	</span>
	<span class="fr fenye">{$db->page->html}</span>
	<div class="clear"></div>
</div>
<!--{include(pe_tpl('footer_dialog.html'));}-->